using System;
using System.Text;
using TccAg.VO;
using TccAg.DA;
using System.Data;
using System.Collections;
using System.Collections.Generic;


namespace TccAg.BR
{
    public class ChoqueBR
    {
        private ChoqueDA choqueDA = new ChoqueDA();

        //INSERIR 
        public int inserir(ChoqueVO choque)
        {
            try
            {
                return choqueDA.inserir(choque);
            }
            catch (Exception ex)
            {
                
                throw ex;
            }
        }

        //ATUALIZAR 
        public int atualizar(ChoqueVO choque)
        {
            try
            {
                return choqueDA.atualizar(choque);
            }
            catch (Exception ex)
            {
                
                throw ex;
            }
        }

        //EXCLUIR 
        public int excluir(ChoqueVO choque)
        {
            try
            {
                return choqueDA.excluir(choque);
            }
            catch (Exception ex)
            {
                
                throw ex;
            }
        }

        //LOAD ALL 
        public List<ChoqueVO> loadAll()
        {
            try
            {
                return choqueDA.loadAll();
            }
            catch (Exception ex)
            {
                
                throw ex;
            }
        }

        //LOAD BY PK
        public ChoqueVO loadByPk(ChoqueVO choque)
        {
            try
            {
                return choqueDA.loadByPk(choque);
            }
            catch (Exception ex)
            {
                
                throw ex;
            }
        }

        //LOAD BY FK
        public List<ChoqueVO> loadByFk(ChoqueVO choque)
        {
            try
            {
                return choqueDA.loadByFk(choque);
            }
            catch (Exception ex)
            {
                
                throw ex;
            }
        }

        //DATATABLE LOAD ALL 
        public DataTable dataTableLoadAll()
        {
            try
            {
                return choqueDA.dataTableLoadAll();
            }
            catch (Exception ex)
            {
                
                throw ex;
            }
        }

    }
}
